<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<input type="text" name="x" oninput="copy()" />
	<input type="text" name="y" />
</body>
<script type="text/javascript">
	function copy(){
		var ind = document.getElementsByTagName('input');
		ind[1].value = ind[0].value;
	}
		
</script>
</html>